<div class="app-ctrl" style="padding-top:76px;overflow: hidden" >
	<div class="b-b app-title-fixed padder">
		<div class="row wrapper-md bg-light">
			<div class="col-sm-9 col-xs-9 padder-sm" >
          		<span class="m-n directory-header h3">
          			<i class="fa fa-key"></i>
          			修改密码
          		</span>
			</div>
	</div>
	</div>
	<div class="bg-light wrapper-xl lter app-inner">
		<form name="form" class="w-xl"  method="post" style="margin: 0 auto;">
			<div ng-show="user.changePassword" class="alert alert-warning alert-dismissable">
				您的密码为不安全的密码，系统强制要求修改
			</div>
			<div ng-show="success" class="alert alert-success alert-dismissable">
				密码修改成功，下次登录使用新密码登录
			</div>
			<div ng-show="cause" class="alert alert-danger alert-dismissable">
				密码修改失败：{{cause}}
			</div>
			<div class="input-group-icon m-b">
			  	<i class="glyphicon glyphicon-lock input-icon"></i>
			  	<input type="password" name="oldPassword" ng-model="oldPassword" class="form-control" placeholder="旧密码" required autofocus>
			</div>
			<div class="input-group-icon m-b">
			 	<i class="glyphicon glyphicon-lock input-icon"></i>
				<input type="password" name="newPassword"  ng-model="newPassword"  class="form-control" ng-change="check()" ng-model-options="{updateOn: 'blur'}" placeholder="新密码" required>
				<span class="help-block m-b-none text-xs text-danger"  ng-show="newPassword.length < appSetting.minLengthOfPassword">密码长度不能小于{{appConfig.minLengthOfPassword}}位</span>
				<span class="help-block m-b-none text-xs text-danger" ng-show="strength < appSetting.passwordStrength">
					<span ng-if="appSetting.passwordStrength == 2">密码必须为数字和字母组合</span>
					<span ng-if="appSetting.passwordStrength == 3">密码必须为数字和字母组合，且必须含有大小写字母</span>
					<span ng-if="appSetting.passwordStrength == 4">密码必须为数字和字母组合，且必须含有大小写字母和特殊字符</span>
				</span>					
			</div>
			<div class="input-group-icon m-b">
			 	<i class="glyphicon glyphicon-lock input-icon"></i>
				<input type="password" name="confirmPassword"  ng-model="confirmPassword" ng-model-options="{updateOn: 'blur'}" class="form-control" placeholder="密码确认" required>
				<span ng-show="confirmPassword && confirmPassword != newPassword" class="help-block m-b-none text-xs text-danger">两次密码不一致</span>
			</div>
			<div class="row" style="margin-top: 8px;">
				<div class="col-xs-12 col-sm-12 col-md-12">
					<button class="btn btn-primary btn-block" ng-click="submit()" type="button" 
					ng-disabled="strength < appSetting.passwordStrength || form.$invalid || !form.$dirty || confirmPassword != newPassword || newPassword.length < appSetting.minLengthOfPassword" >
					确&nbsp;&nbsp;定</button>
				</div>
			</div>
			</form>
		</div>
				
</div>
